<?php

namespace App\Content\Providers;

use App\Content\Contracts\AdvInterface;
use App\Content\Contracts\ArticleInterface;
use App\Content\Repositories\DbAdvRepository;
use App\Content\Repositories\DbArticleRepository;


class AppServiceProvider extends ServiceProvider
{
    /**
     * Bootstrap any application services.
     *
     * @return void
     */
    public function boot()
    {
        require __DIR__.'/../routes.php';
        require __DIR__.'/../admin_routes.php';
    }

    /**
     * Register any application services.
     *
     * @return void
     */
    public function register()
    {
        $this->app->bind(ArticleInterface::class, DbArticleRepository::class); //文章管理
        $this->app->bind(AdvInterface::class, DbAdvRepository::class); //广告管理
    }
}
